package routers

import (
	"github.com/gin-gonic/gin"
	"heightFive/Day_exam/day3/userApi/api"
	"heightFive/Day_exam/day3/userApi/validate"
)

func UserRouter(Router *gin.RouterGroup) {
	UserRouter := Router.Group("user")
	{
		UserRouter.POST("register", api.Register)
		UserRouter.POST("getByUsername", api.GetByUsername)
		UserRouter.Use(validate.Validate)
		UserRouter.GET("chat", api.Chat)
	}
}
